package com.lzq.aopdemo.proxy;

public class HouseProxy implements HouseSubject{
    private HouseSubject houseSubject;

    @Override
    public void rentHouse() {
        //开始代理
        System.out.println("我是中介, 开始代理");
        //代理房东出租房⼦
        houseSubject.rentHouse();
        //代理结束
        System.out.println("我是中介, 代理结束");
    }

    @Override
    public void saleHouse() {
        //开始代理
        System.out.println("我是中介, 开始代理");
        //代理房东出售房⼦
        houseSubject.saleHouse();
        //代理结束
        System.out.println("我是中介, 代理结束");
    }
}
